package com.group;

import com.group.controller.PlaceTextController;
import com.group.entity.Solution;
import com.group.entity.TimeMove;
import com.group.view.MainView;

/**
 * @author zhanglianyong
 * 2022/12/23 10:45
 */
public class Main {

    public static void main(String[] args){
        // 字幕偏移
        TimeMove timeMove = new TimeMove();
        // 视图
        MainView view = new MainView(timeMove);
        view.createView();
        String path = "src/com/group/data/subtitle.srt.txt";
        // 解析字幕文件
        Solution solution = new Solution(path);
        try {
            solution.parseSrt(path);
        } catch (Exception e) {
            e.printStackTrace();
        }
        // 开始播放字幕
        PlaceTextController placeTextController = new PlaceTextController(solution, view, timeMove);
        placeTextController.controller();
    }
}
